<admintpl file="header" />
</head>
<body>
<div class="wrap js-check-wrap">
    <!--<ul class="nav nav-tabs">-->
        <!--<li class="active"><a href="{:U('user/index')}">{:L('ADMIN_USER_INDEX')}</a></li>-->
        <!--<li><a href="{:U('user/add')}">{:L('ADMIN_USER_ADD')}</a></li>-->
    <!--</ul>-->
    <form class="well form-search" method="post" action="{:U('Member/index')}">
        用户名:
        <input type="text" name="user_name" style="width: 100px;" value="{:I('request.user_name/s','')}" placeholder="请输入姓名">
        手机号:
        <input type="text" name="phone" style="width: 100px;" value="{:I('request.phone/s','')}" placeholder="请输入手机号">
        <input type="submit" class="btn btn-primary" value="搜索" />
        <a class="btn btn-danger" href="{:U('Member/index')}">清空</a>
    </form>
    <table class="table table-hover table-bordered">
        <thead>
        <tr>
            <th width="50">ID</th>
            <th> 姓名 </th>
            <th> 头像 </th>
            <th> 手机号 </th>
            <th> 编号 </th>
            <th> 性别 </th>
            <th> 注册时间 </th>
            <th> 状态 </th>
            <th width="200">操作</th>
        </tr>
        </thead>
        <tbody>
        <php>$user_statuses=array("0"=>L('USER_STATUS_BLOCKED'),"1"=>L('USER_STATUS_ACTIVATED'),"2"=>L('USER_STATUS_UNVERIFIED'));</php>
        <foreach name="list" item="vo">
            <tr>
                <td>{$vo.id}</td>
                <td>{$vo['user_name']}</td>
                <td><img style="height: 40px;" src="{$vo['avatar']}" alt=""> </td>
                <td>
                   {$vo['phone']}
                </td>
                <td>{$vo.number}</td>
                <td>
                    <if condition="$vo['sex'] eq 1">
                        男
                        <elseif condition="$vo['sex'] eq 2" />
                        女
                        <else/>
                        保密
                    </if>
                </td>
                <td>
                    {$vo['create_time']}
                </td>
                <td>
                    {$vo['state']}
                </td>
                <td>
                   <a href="{:U('Member/password',array('id'=>$vo['id']))}">修改密码</a> |
                   <if condition="$vo['status'] eq 0">
                       <a href="{:U('Member/watch',array('id'=>$vo['id']))}">查看/编辑</a> |
                       <a href="{:U('Member/reState',array('id'=>$vo['id'],'state'=>5))}">删除</a>
                     <elseif condition="$vo['status'] eq 1" />
                       <a href="{:U('Member/watch',array('id'=>$vo['id']))}">查看/审核</a> |
                       <a href="{:U('Member/reState',array('id'=>$vo['id'],'state'=>5))}">删除</a>
                      <elseif condition = "$vo['status'] eq 2" />
                       <a href="{:U('Member/watch',array('id'=>$vo['id']))}">查看/编辑</a> |
                       <a href="{:U('Member/reState',array('id'=>$vo['id'],'state'=>4))}">禁用</a> |
                       <a href="{:U('Member/reState',array('id'=>$vo['id'],'state'=>5))}">删除</a>
                       <elseif condition = "$vo['status'] eq 3" />
                       <a href="{:U('Member/watch',array('id'=>$vo['id']))}">查看/编辑</a> |
                       <a href="{:U('Member/reState',array('id'=>$vo['id'],'state'=>5))}">删除</a>
                       <elseif condition = "$vo['status'] eq 4" />
                       <a href="{:U('Member/watch',array('id'=>$vo['id']))}">查看/编辑</a> |
                       <a href="{:U('Member/reState',array('id'=>$vo['id'],'state'=>2))}">启用</a> |
                       <a href="{:U('Member/reState',array('id'=>$vo['id'],'state'=>5))}">删除</a>
                   </if>
                </td>
            </tr>
        </foreach>
        </tbody>
    </table>
    <div class="pagination">{$page}</div>
</div>
<script src="__PUBLIC__/js/common.js"></script>
</body>
</html>